package com.example.demo.controller;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController // =  @Controller + @ResponseBody
public class StudentController {

    private static final Logger logger =
            LoggerFactory.getLogger("StudentController");

    @RequestMapping("/stu/sayHi")
    public String sayHi() {
        logger.info("student info");
        logger.error("student error");
        return "student sayHi";
    }

}
